package com.qcxk.yuqian.system.component.task;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.qcxk.yuqian.system.entity.User;
import com.qcxk.yuqian.system.service.UserService;
import com.qcxk.yuqian.system.utils.ThmsUtil;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

import java.util.Date;
import java.util.List;

@Slf4j
@Component
public class TimingTask {

    @Autowired
    private UserService userService;

    /**
     *
     */
    @Scheduled(cron = "${task.cron.timingtask}")
    public void executeFileDownLoadTask() {
        User user = new User();
        user.setState("0");
        QueryWrapper<User> userQueryWrapper = new QueryWrapper<>(user);
        List<User> users = userService.list(userQueryWrapper);
    }
}
